﻿<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:tns="http://tempuri.org/" elementFormDefault="qualified" targetNamespace="http://tempuri.org/" xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <xs:import namespace="http://schemas.datacontract.org/2004/07/MPQService" />
  <xs:import namespace="http://schemas.datacontract.org/2004/07/System" />
  <xs:import namespace="http://schemas.microsoft.com/2003/10/Serialization/Arrays" />
  <xs:element name="Hello">
    <xs:complexType>
      <xs:sequence />
    </xs:complexType>
  </xs:element>
  <xs:element name="DoLogin">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Username" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="Password" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="CreateUser">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Username" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="Password" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="ChangePassword">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Username" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="OldPassword" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="NewPassword" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="CreateTeam">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Teamname" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="User" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="JoinTeam">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Teamname" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="User" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="GetGames">
    <xs:complexType>
      <xs:sequence />
    </xs:complexType>
  </xs:element>
  <xs:element name="CreateGame">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="id" type="xs:int" />
        <xs:element minOccurs="0" name="Name" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="GetUserDetails">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Username" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="UpdateUserScores">
    <xs:complexType>
      <xs:sequence />
    </xs:complexType>
  </xs:element>
  <xs:element name="UpdateTeamScores">
    <xs:complexType>
      <xs:sequence />
    </xs:complexType>
  </xs:element>
  <xs:element name="RegisterClient">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameID" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="RegisterHost">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameID" type="xs:int" />
        <xs:element minOccurs="0" name="Name" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="QuizFile" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="RegisterUser">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameID" type="xs:int" />
        <xs:element minOccurs="0" name="Name" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="UnregisterClient">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameID" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="UnregisterUser">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameID" type="xs:int" />
        <xs:element minOccurs="0" name="ID" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="GetGameDetails">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameID" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="ReadyToStart">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameID" type="xs:int" />
        <xs:element minOccurs="0" name="ID" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="MultichoiceAnswer">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameID" type="xs:int" />
        <xs:element xmlns:q1="http://schemas.datacontract.org/2004/07/MPQService" minOccurs="0" name="Answer" type="q1:Answer" />
        <xs:element minOccurs="0" name="ID" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="InputAnswer">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameID" type="xs:int" />
        <xs:element minOccurs="0" name="Answer" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="ID" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OutOfTime">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameID" type="xs:int" />
        <xs:element minOccurs="0" name="ID" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="GetQuizFiles">
    <xs:complexType>
      <xs:sequence />
    </xs:complexType>
  </xs:element>
  <xs:element name="UploadQuizFile">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="QuizFile" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="Name" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="PartNo" type="xs:int" />
        <xs:element minOccurs="0" name="TotalParts" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="StartQuiz">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameID" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="GetHaveHost">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameID" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="Goodbye">
    <xs:complexType>
      <xs:sequence />
    </xs:complexType>
  </xs:element>
  <xs:element name="IncorrectPassword">
    <xs:complexType>
      <xs:sequence />
    </xs:complexType>
  </xs:element>
  <xs:element name="SetUserMultipler">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Username" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="Multiplier" type="xs:double" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnHello">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="SingleGame" type="xs:boolean" />
        <xs:element xmlns:q2="http://schemas.datacontract.org/2004/07/MPQService" minOccurs="0" name="ServerMessages" nillable="true" type="q2:ArrayOfServerMessage" />
        <xs:element minOccurs="0" name="ServerRequiresPassword" type="xs:boolean" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnLoginSuccess">
    <xs:complexType>
      <xs:sequence />
    </xs:complexType>
  </xs:element>
  <xs:element name="OnLoginFail">
    <xs:complexType>
      <xs:sequence />
    </xs:complexType>
  </xs:element>
  <xs:element name="OnCreateUserFail">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Reason" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnChangePassword">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Success" type="xs:boolean" />
        <xs:element xmlns:q3="http://schemas.datacontract.org/2004/07/System" minOccurs="0" name="Exception" nillable="true" type="q3:Exception" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnFailUpload">
    <xs:complexType>
      <xs:sequence>
        <xs:element xmlns:q4="http://schemas.datacontract.org/2004/07/System" minOccurs="0" name="Exception" nillable="true" type="q4:Exception" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnGetGames">
    <xs:complexType>
      <xs:sequence>
        <xs:element xmlns:q5="http://schemas.microsoft.com/2003/10/Serialization/Arrays" minOccurs="0" name="Games" nillable="true" type="q5:ArrayOfKeyValueOfstringint" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnGetUserDetails">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Score" type="xs:int" />
        <xs:element minOccurs="0" name="TeamName" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="TimeMultiplier" type="xs:double" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnUpdateUserScores">
    <xs:complexType>
      <xs:sequence>
        <xs:element xmlns:q6="http://schemas.microsoft.com/2003/10/Serialization/Arrays" minOccurs="0" name="Scores" nillable="true" type="q6:ArrayOfKeyValueOfstringlong" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnUpdateTeamScores">
    <xs:complexType>
      <xs:sequence>
        <xs:element xmlns:q7="http://schemas.microsoft.com/2003/10/Serialization/Arrays" minOccurs="0" name="Scores" nillable="true" type="q7:ArrayOfKeyValueOfstringlong" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnRegisterClient">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="GameName" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnFailRegisterClient">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Reason" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnGetGameDetails">
    <xs:complexType>
      <xs:sequence>
        <xs:element xmlns:q8="http://schemas.datacontract.org/2004/07/MPQService" minOccurs="0" name="Details" nillable="true" type="q8:GameDetails" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="SendQuestion">
    <xs:complexType>
      <xs:sequence>
        <xs:element xmlns:q9="http://schemas.datacontract.org/2004/07/MPQService" minOccurs="0" name="Question" type="q9:Question" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="Start">
    <xs:complexType>
      <xs:sequence />
    </xs:complexType>
  </xs:element>
  <xs:element name="UpdateGameScores">
    <xs:complexType>
      <xs:sequence>
        <xs:element xmlns:q10="http://schemas.microsoft.com/2003/10/Serialization/Arrays" minOccurs="0" name="Scores" nillable="true" type="q10:ArrayOfKeyValueOfstringlong" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="SendStatus">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Status" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="Detail" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnRegisterHost">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="ID" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnRegisterUser">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="ID" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnCorrectAnswer">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="Explanation" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnIncorrectAnswer">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="CorrectAnswer" nillable="true" type="xs:string" />
        <xs:element minOccurs="0" name="Explanation" nillable="true" type="xs:string" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="HaveHost">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="HaveHost" type="xs:boolean" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnGetQuizFiles">
    <xs:complexType>
      <xs:sequence>
        <xs:element xmlns:q11="http://schemas.microsoft.com/2003/10/Serialization/Arrays" minOccurs="0" name="Files" nillable="true" type="q11:ArrayOfstring" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="EndOfQuiz">
    <xs:complexType>
      <xs:sequence>
        <xs:element minOccurs="0" name="UserScore" type="xs:int" />
        <xs:element minOccurs="0" name="TotalQuestions" type="xs:int" />
      </xs:sequence>
    </xs:complexType>
  </xs:element>
  <xs:element name="OnIncorrectServerPassword">
    <xs:complexType>
      <xs:sequence />
    </xs:complexType>
  </xs:element>
</xs:schema>